package com.czl.elm.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;

import java.time.LocalDateTime;


@Data
@Document("redParper")
@NoArgsConstructor
@AllArgsConstructor
public class RedParper {
    @Id
    @TableId(value = "redParper")
    @ApiModelProperty("红包id")
    private String redParperId;
    @ApiModelProperty("优惠券id")
    private String redShopParperId;
    @ApiModelProperty("获取用户id")
    private String phoneName;
    @ApiModelProperty("商店id")
    private Integer shopId;
    @ApiModelProperty("商店名称")
    private String shopName;
    @ApiModelProperty("商店图片url")
    private String shopUrl;
    @ApiModelProperty("起始时间")
    private LocalDateTime startTime;
    @ApiModelProperty("中止时间")
    private LocalDateTime endTime;
    @ApiModelProperty("获取时间")
    private LocalDateTime getTime;
    @ApiModelProperty("使用时长")
    private LocalDateTime useTime;
    @ApiModelProperty("满减上限，满50减30中的50")
    private Integer fullReduction;
    @ApiModelProperty("满减金额，满50减30中的30")
    private Integer reduction;
    @TableField(exist = false)
    @ApiModelProperty("红包状态,-2/-1/0/1/2：已使用/已过期/无状态/新获得/即将到期")
    private Integer tag;

}
